// @Time：2022/2/16 10:49
// @Software：GoLand
// @Author：JentZhang
package routers

import (
	"github.com/gin-gonic/gin"

	"simple_oa/controller"
	"simple_oa/middlewares"
)

func LoadAdminRouter(g *gin.Engine) {
	jwtAuthMiddleware := middlewares.JWTAuthMiddleware()

	adminGroup := g.Group("admin")
	adminGroup.Use(jwtAuthMiddleware)
	{
		adminGroup.GET("/", controller.AdminIndexHandler)
		adminGroup.GET("/staff", controller.StaffHandler)
	}
}
